<?php
namespace catchAdmin\apipatient\validate;

use think\Validate;

class EdValidate extends Validate
{
    protected $rule = [
        'classify' => 'require',
        'type' => 'require',
        'ed_id' => 'require',
        'id' => 'require',
        'sign' => 'require|chsAlpha'
    ];

    protected $message = [
        'classify.require' => '缺少classify参数',
        'type.require' => '缺少type参数',
        'ed_id.require' => '缺少ed_id参数',
        'id.require' => '缺少ID参数',
        'sign.require' => '缺少签名参数',
        'sign.chsAlpha' => '签名只允许字母或汉字',
    ];

    protected $scene = [
        'get_ed_list' => ['classify'],
        'get_ed_jkys' => ['type'],
        'get_ed_detail' => ['ed_id'],
        'get_my_ed_detail' => ['id', 'type', 'ed_id'],
        'inhospital_ed_sign' => ['id', 'type', 'sign'],
        'get_hzd_satisfied_quest' => ['classify'],
    ];  
}